package com.docker.apps.afterservice.api;

import android.arch.lifecycle.LiveData;

import com.docker.apps.order.vo.AfterServiceVo;
import com.docker.apps.order.vo.InvoiceVo;
import com.docker.apps.order.vo.InvoiceVov2;
import com.docker.apps.order.vo.RefundOrderVo;
import com.docker.apps.order.vo.ServiceDetailVo;
import com.docker.common.common.vo.entity.ReasonEntity;
import com.docker.core.di.netmodule.ApiResponse;
import com.docker.core.di.netmodule.BaseResponse;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import retrofit2.http.Field;
import retrofit2.http.FieldMap;
import retrofit2.http.FormUrlEncoded;
import retrofit2.http.POST;

public interface AfterService {

    @POST("api.php?m=order.tuik")
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<String>>> tuikuan(@FieldMap HashMap<String, String> paramMap);

    @POST("api.php?m=order.service_show")
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<ServiceDetailVo>>> serviceShow(@FieldMap HashMap<String, String> paramMap);

    @POST("api.php?m=order.tuik_show")
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<RefundOrderVo>>> tuiShow(@FieldMap HashMap<String, String> paramMap);

    @POST("api.php?m=order.cancel_tuik")
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<String>>> cancelTui(@FieldMap HashMap<String, String> paramMap);

    @POST("api.php?m=order.cancel_service")
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<String>>> cancelService(@FieldMap HashMap<String, String> paramMap);

    //单个订单包含的商品列表
    @POST("api.php?m=order.returnGoods")
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<String>>> returnGoods(@FieldMap HashMap<String, String> paramMap);

    @POST("api.php?m=order.invoiceInfo")
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<InvoiceVov2>>> invoice_show(@FieldMap HashMap<String, String> paramMap);

    @POST("api.php?m=order.return_list")  //api.php?m=order.return_list
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<List<AfterServiceVo.AfterServiceGood>>>> return_list(@FieldMap HashMap<String, String> paramMap);

    @POST("api.php?m=order.returnAuditList")  //api.php?m=order.return_list
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<List<AfterServiceVo.AfterServiceGood>>>> returnAuditList(@FieldMap HashMap<String, String> paramMap);


    @POST("api.php?m=order.invoiceList")  //api.php?m=order.return_list
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<List<InvoiceVov2>>>> invoiceList(@FieldMap HashMap<String, String> paramMap);


    @POST("api.php?m=order.return_logistics")
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<String>>> return_logistics(@FieldMap HashMap<String, String> paramMap);


    @POST("api.php?m=publics.linkage")
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<List<ReasonEntity>>>> refund_reason(@Field("keyid") String str);


    @POST("api.php?m=order.setInvoice")
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<String>>> setInvoice(@FieldMap Map<String, String> paramMap);

    @POST("api.php?m=order.delInvoice")
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<String>>> delInvoice(@FieldMap Map<String, String> paramMap);

    @POST("api.php?m=order.getInvoice")
    @FormUrlEncoded
    LiveData<ApiResponse<BaseResponse<String>>> handInvoice(@FieldMap Map<String, String> paramMap);

}
